import { mapGetters } from "vuex";
 export default {
   computed:{
     ...mapGetters('m_cart',['total'])
   },
   methods:{
     setTabBarBadge(){
       uni.setTabBarBadge({
         index:2,
         text:String(this.total)
       })
     }
   },
   onShow() {
     this.setTabBarBadge();
   },
   watch:{
     'total'(newval){
       this.setTabBarBadge()
     }
   }
 }